package com.cicc.beergamevirtualsimulationsystem.context;

import com.cicc.beergamevirtualsimulationsystem.entity.UserEntity;

/**
 * 存放线程变量
 */
public class BaseContext {

    public static ThreadLocal<String> threadLocal = new ThreadLocal<>();

    public static void setCurrentId(String id) {
        threadLocal.set(id);
    }

    public static String getCurrentId() {
        return threadLocal.get();
    }
    public static void removeCurrentId() {
        threadLocal.remove();
    }

}
